import 'dart:math';

import 'package:flutter/services.dart';
import 'package:get/get.dart';
import 'package:yt_devops/components/log_utils.dart';
import 'package:yt_devops/pages/devices/device_tab/device_detail/new_air_cooling_page/component/char_x.dart';

class TemperatureFullChartController extends GetxController {
  List<dynamic> gunTemperatureData = []; //枪温度
  List<dynamic> maxTemperatureData = []; //单体电池最高温度
  List<dynamic> minTemperatureData = []; //单体电池最低温度
  List<dynamic> gunPositiveTemperatureData = []; //充电枪正极温度
  List<dynamic> gunNegativeTemperatureData = []; //充电枪负极温度
  @override
  void onInit() {
    super.onInit();
    if (Get.arguments != null) {
      if (Get.arguments['gunTemperatureData'] != null) {
        gunTemperatureData = Get.arguments['gunTemperatureData'];
      }
      if (Get.arguments['maxTemperatureData'] != null) {
        maxTemperatureData = Get.arguments['maxTemperatureData'];
      }
      if (Get.arguments['minTemperatureData'] != null) {
        minTemperatureData = Get.arguments['minTemperatureData'];
      }
      if (Get.arguments['gunPositiveTemperatureData'] != null) {
        gunPositiveTemperatureData =
            Get.arguments['gunPositiveTemperatureData'];
      }
      if (Get.arguments['gunNegativeTemperatureData'] != null) {
        gunNegativeTemperatureData =
            Get.arguments['gunNegativeTemperatureData'];
      }
      Log.d('gunPositiveTemperatureData==' + gunPositiveTemperatureData.toString());
    }
  }

  @override
  void onReady() {}

  @override
  void onClose() {}
}
